{extend name="base" /}
{block name="css"}
<link href="__ADMIN__/js/ztree/css/zTreeStyle/zTreeStyle.css?v={$v}" rel="stylesheet" type="text/css" />
<link rel="stylesheet" type="text/css" href="__STATIC__/plugins/webuploader/webuploader.css?v={$v}" />
<style>
    .desc{width:90%;height:auto;word-break: break-all;}
    .feedback-content-gallery{margin:10px 10px 10px 10px;}
    .feedback-content-gallery img{width:100px;height:100px;object-fit:cover;margin:5px 5px 0 0;cursor: pointer;}
</style>
{/block}
{block name="js"}
<script src="__ADMIN__/js/ztree/jquery.ztree.all-3.5.js?v={$v}"></script>
<script src="__STATIC__/plugins/webuploader/webuploader.js?v={$v}" type="text/javascript" ></script>
<script src="__STATIC__/plugins/kindeditor/kindeditor.js?v={$v}" type="text/javascript" ></script>
<script src="__ADMIN__/feedbacks/feedbacks.js?v={$v}" type="text/javascript"></script>
<script>
    $(function () {
        {if condition="$object['feedbackId'] !=0 "}
        WST.setValues({$object});
        {/if}
            $('#feedbackForm').validator({
                fields: {
                    handleContent: {
                        tip: "请输入回复内容",
                        rule: '回复内容:required;'
                    }
                },
                valid: function(form){
                    var feedbackId = $('#feedbackId').val();
                    toEdits(feedbackId,{$p});
                }
            })
        });
</script>
{/block}
{block name="main"}
<input type='hidden' id='feedbackId' value='{$object["feedbackId"]}'/>
<form id='feedbackForm' autocomplete="off">
    <table class='wst-form '>
        <tr>
            <th width='150'>反馈用户：</th>
            <td width='150'>{$object['userName']}</td>
            <th width='150'>反馈类型：</th>
            <td>{$object['feedbackType']}</td>
        </tr>
        <tr>
            <th>联系方式：</th>
            <td>{$object['contactInfo']}</td>
            <th>创建时间：</th>
            <td>{$object['createTime']}</td>
        </tr>
        <tr>
            <th>反馈内容：</th>
            <td colspan="3">
                <div class="desc">
                    {$object['feedbackContent']}
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="4" align="center"><div style='border:1px dotted #eee;width:96%;margin-bottom:5px;margin-top:5px'></div></td>
        </tr>
        {if condition="$object['feedbackStatus'] eq 1"}
        <tr>
            <th width='150' >回复人：</th>
            <td width='150'>{$object['staffName']}</td>
            <th width='150'>回复时间：</th>
            <td>{$object['handleTime']}</td>
        </tr>
        <tr>
            <th width='150' >回复内容：</th>
            <td colspan="3">
                <div class="desc">
                    {$object['handleContent']}
                </div>
            </td>
        </tr>
        <tr>
            <td colspan='4' align='center'>
                <button type="button" class="btn" onclick="javascript:location.href='{:Url(\'admin/feedbacks/index\',\'p=\'.$p)}'"><i class="fa fa-angle-double-left"></i>返&nbsp;回</button>
            </td>
        </tr>
        {else}
        <tr>
            <th width='150' >回复内容<font color='red'>*</font>：</th>
            <td colspan="3">
                <textarea id='handleContent' name='handleContent' class="ipt"  cols="30" rows="10" ></textarea>
            </td>
        </tr>
        <tr>
            <td colspan='4' align='center'>
                <button type="submit" class="btn btn-primary btn-mright" ><i class="fa fa-check"></i>回&nbsp;复</button>
                <button type="button" class="btn" onclick="javascript:location.href='{:Url(\'admin/feedbacks/index\',\'p=\'.$p)}'"><i class="fa fa-angle-double-left"></i>返&nbsp;回</button>
            </td>
        </tr>
        {/if}

    </table>
</form>
<script>
    $(function(){

    });
</script>
{/block}